package net.huashitong.ssydt.msg.entity.vo;

import io.swagger.annotations.ApiModelProperty;
import net.huashitong.ssydt.msg.entity.SsMsgMessage;

import java.io.Serializable;
import java.util.Date;

/**
 * @author <a href="mailto:yhy23456@163.com">huiyang.yu</a>
 * @since 2017.11.14
 */
public class MessageOutVO implements Serializable {

    private static final long serialVersionUID = -1040400085587009143L;

    @ApiModelProperty(value = "标题")
    private String title;//标题
    @ApiModelProperty(value = "内容")
    private String text;//内容
    @ApiModelProperty(value = "目标(关联id或url)")
    private String target;//目标
    @ApiModelProperty(value = "目标类型 01网页 02文章 03文章测评 04题库测评 05评论或点赞")
    private String targetType;//目标类型
    @ApiModelProperty(value = "发送者")
    private String sender;//发送者
    @ApiModelProperty(value = "动作")
    private String action;//动作
    @ApiModelProperty(value = "时间")
    private Date gmtCreate;
    @ApiModelProperty(value = "消息id")
    private Long messageId;
    @ApiModelProperty("消息类型 01系统 02评论")
    private String msgType;//消息类型

    public MessageOutVO(SsMsgMessage message) {
        this.title = message.getTitle();
        this.text = message.getText();
        this.target = message.getTarget();
        this.targetType = message.getTargetType();
        this.sender = message.getSender();
        this.action = message.getAction();
        this.gmtCreate = message.getGmtCreate();
        this.messageId = message.getId();
        this.msgType = message.getMsgType();
    }

    public MessageOutVO() {
    }

    public String getTitle() {
        return title;
    }

    public void setTitle(String title) {
        this.title = title;
    }

    public String getText() {
        return text;
    }

    public void setText(String text) {
        this.text = text;
    }

    public String getTarget() {
        return target;
    }

    public void setTarget(String target) {
        this.target = target;
    }

    public String getTargetType() {
        return targetType;
    }

    public void setTargetType(String targetType) {
        this.targetType = targetType;
    }

    public String getSender() {
        return sender;
    }

    public void setSender(String sender) {
        this.sender = sender;
    }

    public String getAction() {
        return action;
    }

    public void setAction(String action) {
        this.action = action;
    }

    public Date getGmtCreate() {
        return gmtCreate;
    }

    public void setGmtCreate(Date gmtCreate) {
        this.gmtCreate = gmtCreate;
    }

    public Long getMessageId() {
        return messageId;
    }

    public void setMessageId(Long messageId) {
        this.messageId = messageId;
    }

    public String getMsgType() {
        return msgType;
    }

    public void setMsgType(String msgType) {
        this.msgType = msgType;
    }
}
